﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Btssio.Musique;
namespace dllTeamTard
{
    public class Event
    {
        #region champs

        private string _url ="inconnu";

        private string _id = "inconnu";

        private string _titre = "inconnu";

        private string _description = "inconnu";

        private string _lienImage = "inconnu";

        private DateTime _dateDeDebut = System.DateTime.Today;

        private string _heureDeDebut = "inconnu";

        private string _lienSiteWeb = "inconnu";

        private int _nbparticipant = 0;
         
        private List<Artist> _participationArtist = new List<Artist>();

        private Venue _uneVenue = null;

        #endregion

        #region propriété

        public string url
        {
            get {return _url;}
            private set { _url = value;}
        }

        public Venue uneVenue
        {
            get { return _uneVenue; }
            private set { _uneVenue = value; }
        }

public int nbparticipant
{
    get {return _nbparticipant;}
    private set {_nbparticipant = value;}
}

public string id
{
    get { return _id; }
    private set { _id = value; }
}
public string titre
{
    get { return _titre; }
    private  set { _titre = value; }
}


public string description{

   get { return _description; }
   private set { _description = value; }
}

public string lienImage
{
    get { return _lienImage; }
    private set { _lienImage = value; }
}

public DateTime dateDeDebut
{
    get { return _dateDeDebut; }
    private set { _dateDeDebut = value; }
}

public string heureDeDebut
{
    get { return _heureDeDebut; }
    private set { _heureDeDebut = value; }
}
public string lienSiteWeb
{
    get { return _lienSiteWeb; }
    private set { _lienSiteWeb = value; }
}

public List<Artist> participationArtist
{
    get {return _participationArtist;}
    internal set {_participationArtist = value;}
}
        #endregion

        #region constructeur

public Event()
{
}
public Event (string id,string titre,string description,int nbparticipant)
    {
        this.id = id;
        this.titre = titre;
        this.description = description;
        this.nbparticipant = nbparticipant;
    }
public Event(string id, string titre, string description, DateTime dateDeDebut,string heureDeDebut,ValueType uneValue )
{
    this.id = id;
    this.titre = titre;
    this.description = description;
    this.dateDeDebut  = dateDeDebut;
    this.heureDeDebut = heureDeDebut;
    this.uneVenue = uneVenue;
}
public Event(string id, string titre, string description, DateTime dateDeDebut,string heureDeDebut, string lienImage, string lienSiteWeb,ValueType uneValue)
{
    this.id = id;
    this.titre = titre;
    this.description = description;
    this.dateDeDebut = dateDeDebut;
    this.heureDeDebut = heureDeDebut;
    this.lienImage=lienImage;
    this.lienSiteWeb = lienSiteWeb;
    this.uneVenue = uneVenue;
}
        public Event (string id, string titre, string url, string description, string lienImage,DateTime dateDeDebut)
    {
        this.id = id;
        this.titre = titre;
        this.url = url;
        this.description = description;
        this.lienImage = lienImage;
        this.dateDeDebut = dateDeDebut;
    }
        #endregion 

        #region methode

        public void addArtist(Artist unArtist)
        {
            if (participationArtist == null)
                participationArtist = new List<Artist>();
            participationArtist.Add(unArtist);
            nbparticipant++;
        }


        #endregion

        #region asseceur

    internal List<Artist> getParticipationArtist()
    {
        return participationArtist;
    }


#endregion 
    }
}
